3.194 \(\int \left (a+b x^n\right )^2 \left (d+e x^n\right )^2 \, dx\)

Optimal. Leaf size=112 \[ \frac{x^{2 n+1} \left (a^2 e^2+4 a b d e+b^2 d^2\right )}{2 n+1}+a^2 d^2 x+\frac{2 a d x^{n+1} (a e+b d)}{n+1}+\frac{2 b e x^{3 n+1} (a e+b d)}{3 n+1}+\frac{b^2 e^2 x^{4 n+1}}{4 n+1} \]

[Out]

a^2*d^2*x + (2*a*d*(b*d + a*e)*x^(1 + n))/(1 + n) + ((b^2*d^2 + 4*a*b*d*e + a^2*
e^2)*x^(1 + 2*n))/(1 + 2*n) + (2*b*e*(b*d + a*e)*x^(1 + 3*n))/(1 + 3*n) + (b^2*e
^2*x^(1 + 4*n))/(1 + 4*n)

_______________________________________________________________________________________

Rubi [A]  time = 0.187095, antiderivative size = 112, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 19, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.053 \[ \frac{x^{2 n+1} \left (a^2 e^2+4 a b d e+b^2 d^2\right )}{2 n+1}+a^2 d^2 x+\frac{2 a d x^{n+1} (a e+b d)}{n+1}+\frac{2 b e x^{3 n+1} (a e+b d)}{3 n+1}+\frac{b^2 e^2 x^{4 n+1}}{4 n+1} \]

Antiderivative was successfully verified.

[In]  Int[(a + b*x^n)^2*(d + e*x^n)^2,x]

[Out]

a^2*d^2*x + (2*a*d*(b*d + a*e)*x^(1 + n))/(1 + n) + ((b^2*d^2 + 4*a*b*d*e + a^2*
e^2)*x^(1 + 2*n))/(1 + 2*n) + (2*b*e*(b*d + a*e)*x^(1 + 3*n))/(1 + 3*n) + (b^2*e
^2*x^(1 + 4*n))/(1 + 4*n)

_______________________________________________________________________________________

Rubi in Sympy [F]  time = 0., size = 0, normalized size = 0. \[ \frac{2 a d x^{n + 1} \left (a e + b d\right )}{n + 1} + \frac{b^{2} e^{2} x^{4 n + 1}}{4 n + 1} + \frac{2 b e x^{3 n + 1} \left (a e + b d\right )}{3 n + 1} + d^{2} \int a^{2}\, dx + \frac{x^{2 n + 1} \left (a^{2} e^{2} + b d \left (4 a e + b d\right )\right )}{2 n + 1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((a+b*x**n)**2*(d+e*x**n)**2,x)

[Out]

2*a*d*x**(n + 1)*(a*e + b*d)/(n + 1) + b**2*e**2*x**(4*n + 1)/(4*n + 1) + 2*b*e*
x**(3*n + 1)*(a*e + b*d)/(3*n + 1) + d**2*Integral(a**2, x) + x**(2*n + 1)*(a**2
*e**2 + b*d*(4*a*e + b*d))/(2*n + 1)

_______________________________________________________________________________________

Mathematica [A]  time = 0.25921, size = 105, normalized size = 0.94 \[ x \left (\frac{x^{2 n} \left (a^2 e^2+4 a b d e+b^2 d^2\right )}{2 n+1}+a^2 d^2+\frac{2 b e x^{3 n} (a e+b d)}{3 n+1}+\frac{2 a d x^n (a e+b d)}{n+1}+\frac{b^2 e^2 x^{4 n}}{4 n+1}\right ) \]

Antiderivative was successfully verified.

[In]  Integrate[(a + b*x^n)^2*(d + e*x^n)^2,x]

[Out]

x*(a^2*d^2 + (2*a*d*(b*d + a*e)*x^n)/(1 + n) + ((b^2*d^2 + 4*a*b*d*e + a^2*e^2)*
x^(2*n))/(1 + 2*n) + (2*b*e*(b*d + a*e)*x^(3*n))/(1 + 3*n) + (b^2*e^2*x^(4*n))/(
1 + 4*n))

_______________________________________________________________________________________

Maple [A]  time = 0.017, size = 117, normalized size = 1. \[{a}^{2}{d}^{2}x+{\frac{ \left ({a}^{2}{e}^{2}+4\,abde+{b}^{2}{d}^{2} \right ) x \left ({{\rm e}^{n\ln \left ( x \right ) }} \right ) ^{2}}{1+2\,n}}+{\frac{{b}^{2}{e}^{2}x \left ({{\rm e}^{n\ln \left ( x \right ) }} \right ) ^{4}}{1+4\,n}}+2\,{\frac{ad \left ( ae+bd \right ) x{{\rm e}^{n\ln \left ( x \right ) }}}{1+n}}+2\,{\frac{be \left ( ae+bd \right ) x \left ({{\rm e}^{n\ln \left ( x \right ) }} \right ) ^{3}}{1+3\,n}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((a+b*x^n)^2*(d+e*x^n)^2,x)

[Out]

a^2*d^2*x+(a^2*e^2+4*a*b*d*e+b^2*d^2)/(1+2*n)*x*exp(n*ln(x))^2+b^2*e^2/(1+4*n)*x
*exp(n*ln(x))^4+2*a*d*(a*e+b*d)/(1+n)*x*exp(n*ln(x))+2*b*e*(a*e+b*d)/(1+3*n)*x*e
xp(n*ln(x))^3

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \text{Exception raised: ValueError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x^n + a)^2*(e*x^n + d)^2,x, algorithm="maxima")

[Out]

Exception raised: ValueError

_______________________________________________________________________________________

Fricas [A]  time = 0.255879, size = 500, normalized size = 4.46 \[ \frac{{\left (6 \, b^{2} e^{2} n^{3} + 11 \, b^{2} e^{2} n^{2} + 6 \, b^{2} e^{2} n + b^{2} e^{2}\right )} x x^{4 \, n} + 2 \,{\left (b^{2} d e + a b e^{2} + 8 \,{\left (b^{2} d e + a b e^{2}\right )} n^{3} + 14 \,{\left (b^{2} d e + a b e^{2}\right )} n^{2} + 7 \,{\left (b^{2} d e + a b e^{2}\right )} n\right )} x x^{3 \, n} +{\left (b^{2} d^{2} + 4 \, a b d e + a^{2} e^{2} + 12 \,{\left (b^{2} d^{2} + 4 \, a b d e + a^{2} e^{2}\right )} n^{3} + 19 \,{\left (b^{2} d^{2} + 4 \, a b d e + a^{2} e^{2}\right )} n^{2} + 8 \,{\left (b^{2} d^{2} + 4 \, a b d e + a^{2} e^{2}\right )} n\right )} x x^{2 \, n} + 2 \,{\left (a b d^{2} + a^{2} d e + 24 \,{\left (a b d^{2} + a^{2} d e\right )} n^{3} + 26 \,{\left (a b d^{2} + a^{2} d e\right )} n^{2} + 9 \,{\left (a b d^{2} + a^{2} d e\right )} n\right )} x x^{n} +{\left (24 \, a^{2} d^{2} n^{4} + 50 \, a^{2} d^{2} n^{3} + 35 \, a^{2} d^{2} n^{2} + 10 \, a^{2} d^{2} n + a^{2} d^{2}\right )} x}{24 \, n^{4} + 50 \, n^{3} + 35 \, n^{2} + 10 \, n + 1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x^n + a)^2*(e*x^n + d)^2,x, algorithm="fricas")

[Out]

((6*b^2*e^2*n^3 + 11*b^2*e^2*n^2 + 6*b^2*e^2*n + b^2*e^2)*x*x^(4*n) + 2*(b^2*d*e
 + a*b*e^2 + 8*(b^2*d*e + a*b*e^2)*n^3 + 14*(b^2*d*e + a*b*e^2)*n^2 + 7*(b^2*d*e
 + a*b*e^2)*n)*x*x^(3*n) + (b^2*d^2 + 4*a*b*d*e + a^2*e^2 + 12*(b^2*d^2 + 4*a*b*
d*e + a^2*e^2)*n^3 + 19*(b^2*d^2 + 4*a*b*d*e + a^2*e^2)*n^2 + 8*(b^2*d^2 + 4*a*b
*d*e + a^2*e^2)*n)*x*x^(2*n) + 2*(a*b*d^2 + a^2*d*e + 24*(a*b*d^2 + a^2*d*e)*n^3
 + 26*(a*b*d^2 + a^2*d*e)*n^2 + 9*(a*b*d^2 + a^2*d*e)*n)*x*x^n + (24*a^2*d^2*n^4
 + 50*a^2*d^2*n^3 + 35*a^2*d^2*n^2 + 10*a^2*d^2*n + a^2*d^2)*x)/(24*n^4 + 50*n^3
 + 35*n^2 + 10*n + 1)

_______________________________________________________________________________________

Sympy [F(-2)]  time = 0., size = 0, normalized size = 0. \[ \text{Exception raised: TypeError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((a+b*x**n)**2*(d+e*x**n)**2,x)

[Out]

Exception raised: TypeError

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.227152, size = 782, normalized size = 6.98 \[ \text{result too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x^n + a)^2*(e*x^n + d)^2,x, algorithm="giac")

[Out]

(24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